package com.link2room.soundwave.facade.impl;

import com.link2room.common.dto.param.base.BaseL2rParamDto;
import com.link2room.common.jpa.result.QueryResult;
import com.link2room.soundwave.dto.param.manager.PmsHotelManagerParamDto;
import com.link2room.soundwave.dto.result.base.PmsHotelDto;
import com.link2room.soundwave.facade.IPmsHotelHandlerFacadeService;

/**
 * @author sqj88
 * @date 2017/10/17 23:09
 */
public abstract class AbstractPmsHotelHandlerFacadeServiceImpl implements IPmsHotelHandlerFacadeService {

    /**
     * 查询PMS酒店
     * @param baseL2rParamDto
     * @return
     * @throws Exception
     */
    abstract PmsHotelDto findPmsHotel(BaseL2rParamDto baseL2rParamDto)throws Exception;

    /**
     * 查询PMS未匹配酒店列表
     * @param baseL2rParamDto
     * @return
     * @throws Exception
     */
    abstract QueryResult<PmsHotelDto> listPmsHotelNotMapping(BaseL2rParamDto baseL2rParamDto)throws Exception;

    /**
     * 保存PMS映射酒店
     * @param pmsHotelManagerParamDto
     * @throws Exception
     */
    abstract void savePmsHotel(PmsHotelManagerParamDto pmsHotelManagerParamDto)throws Exception;

    /**
     * 删除PMS映射酒店
     * @param baseL2rParamDto
     * @throws Exception
     */
    abstract void delPmsHotel(BaseL2rParamDto baseL2rParamDto) throws Exception;


    @Override
    public QueryResult<PmsHotelDto> listPmsHotelNotMappingHandler(BaseL2rParamDto baseL2rParamDto) throws Exception{
        return listPmsHotelNotMapping(baseL2rParamDto);
    }

    @Override
    public PmsHotelDto findPmsHotelHandler(BaseL2rParamDto baseL2rParamDto) throws Exception{
        return findPmsHotel(baseL2rParamDto);
    }

    @Override
    public void savePmsHotelHandler(PmsHotelManagerParamDto pmsHotelManagerParamDto)throws Exception{
        savePmsHotel(pmsHotelManagerParamDto);
    }

    @Override
    public void delPmsHotelHandler(BaseL2rParamDto baseL2rParamDto)throws Exception{
        delPmsHotel(baseL2rParamDto);
    }
}
